<!-- 导航URL -->
<div class="row wrapper border-bottom white-bg page-heading">
    <div class="col-md-12">
        <ol class="breadcrumb">
            <li><a href="#/service/addService">主页</a></li>
            <li><a>工单管理</a></li>
            <li class="active"><strong>预警记录</strong></li>
        </ol>
    </div>
</div>
<!-- 主要内容 -->
<div class="wrapper wrapper-content animated fadeIn" ng-controller="workWarningQueryCtrl">
    <form class="form-horizontal" id="form1">
        <div class="row">
            <div class="col-lg-12">
                <div class="panel-body ibox float-e-margins">
                    <div class="ibox-title">
                        <h5>预警记录查询</h5>
                    </div>
                    <div class="ibox-content">
                        <div class="form-group">
                            <label class="col-sm-2 control-label">ID：</label>
                            <div class="col-sm-2">
                                <input type="text" class="form-control" ng-model="info.id" placeholder="请输入ID">
                            </div>
                            <div >
                                <label class="col-sm-2 control-label" >代理商：</label>
                                <div class="col-sm-2" >
                                    <select name="autocomplete-select2" id="autocomplete-select2" ng-model="info.agentNo"
                                            ng-options="x.value as x.text for x in agentList" style="width: 100%"
                                            chosen chosen-data="agentList" chosen-keyup="getAgentList">
                                    </select>
                                </div>
                            </div>
                        </div>
                        <div class="form-group">
                            <label class="col-sm-2 control-label">预警时间：</label>
                            <div class="col-sm-6">
                                <input id="d5223" class="form-control" type="datetime" ng-model="info.createTimeBegin" onchange=""  style="width:auto;display:inline-block;" placeholder="开始日期"
                                       onFocus="var d5224=$dp.$('d5224');WdatePicker({skin:'whyGreen',dateFmt: 'yyyy-MM-dd HH:mm:ss',onpicked:function(){d5224.focus();},maxDate:'#F{$dp.$D(\'d5224\')}'})"/>
                                ~
                                <input id="d5224" class="form-control" type="datetime"  ng-model="info.createTimeEnd" onchange=""  style="width:auto;display:inline-block;" placeholder="结束日期"
                                       onFocus="WdatePicker({skin:'whyGreen',dateFmt: 'yyyy-MM-dd HH:mm:ss',minDate:'#F{$dp.$D(\'d5223\')}'})"/>
                            </div>
                        </div>
                        <div class="form-group">
                            <label class="col-sm-2 control-label"></label>
                            <div class="col-sm-8">
                                <button class="btn btn-primary6 btn-mr20" ng-click="query()">查询</button>
                                <button class="btn btn-primary3 btn-mr20" type="button" ng-click="resetForm()">清空</button>
                            </div>
                        </div>
                    </div>

                    <div class="panel-body ibox float-e-margins">
                        <div class="ibox-title">
                            <h5>查询列表</h5>
                        </div>
                        <div class="ibox-content">
                            <div class="gridStyle" ui-grid="myGrid" ui-grid-selection ui-grid-pagination
                                 ui-grid-resize-columns ui-grid-pinning></div>
                            <div ng-show="loadImg" class="timg"></div>
                        </div>
                    </div>
                    <div style="height:30px;"></div>
                </div>
            </div>
        </div>
    </form>

    <div id="replyModal" class="modal fade form-horizontal" tabindex="4" role="dialog">
        <div class="modal-dialog" style="height:450px;width:900px">
            <div class="modal-content" >
                <form class="form-horizontal" name="horizontalCard"  novalidate>
                    <div class="modal-header">
                        <button type="button" class="close" data-dismiss="modal">
                            &times;</button>
                        <h3 class="modal-title">回复工单</h3>
                    </div>
                    <div class="modal-body">
                        <div class="form-group">
                            <label class="col-sm-2 control-label"><i class="red_req">*</i>回复内容:</label>
                            <div class="col-sm-7">
                                <textarea class="form-control" rows="4" cols="15" name="replyContent" required maxlength="300" ng-model="reply.replyContent" placeholder="请输入回复内容，不超过300字"></textarea>
                                <div class="req_mesg" ng-show="horizontalCard.replyContent.$dirty && horizontalCard.replyContent.$invalid">
                                    <span ng-show="horizontalCard.replyContent.$error.required">回复内容不能为空</span>
                                </div>
                            </div>
                        </div>

                        <div class="form-group">
                            <label class="col-sm-2 control-label">添加附件:</label>
                            <div class="col-sm-3 checkbox ">
                                <input type="file" nv-file-select="" ng-model="fileSelect" uploader="uploader" multiple/>
                                <table class="table">
                                    <tbody>
                                    <tr ng-repeat="item in uploader.queue">
                                        <td>
                                            <strong>{{ item.file.name }}</strong>
                                        </td>
                                        <td nowrap>
                                            <button type="button" class="btn btn-danger btn-xs" ng-click="item.remove()">
                                                <span class="glyphicon glyphicon-trash"></span>删除
                                            </button>
                                        </td>
                                    </tr>
                                    </tbody>
                                </table>
                            </div>
                            <label style="margin-top:7px;color: red">注:最多可上传15个文件,每个文件小于10M,文件名称小于50个字</label>
                        </div>
                    </div>
                    <div class="modal-footer">
                        <div class="form-group control-label">
                            <label class="col-sm-1 control-label"></label>
                            <div class="col-sm-6">
                                <button class="btn btn-primary btn-mr20" ng-disabled="horizontalCard.$invalid" type="button" ng-click='commitReply()' >确定</button>
                                <button class="btn btn-primary4" type="button" ng-click='closeReplyModal()'>返回</button>
                            </div>
                        </div>
                    </div>
                </form>
            </div>
        </div>
    </div>

</div>


</div>